﻿using MvcSimplyCleverPart2.Models;
using System.Web.Mvc;

namespace MvcSimplyCleverPart2.Controllers
{
    public class ContactController : Controller
    {
        [SetDefaultValueAttribute]
        public ActionResult Index()
        {
            return View();
        }

        [HttpPost]
        public ActionResult Save(AddressViewModel model)
        {
            if (ModelState.IsValid)
                return View(model);

            return View("Index", model);
        }

    }
}
